﻿<MSwitch @bind-Value="html" HideDetails="true" Label="html: Enable HTML tags in source"></MSwitch>
<MSwitch @bind-Value="breaks" HideDetails="true" Label="breaks: Convert '\n' in paragraphs into <br>"></MSwitch>
<MSwitch @bind-Value="linkify" HideDetails="true" Label="linkify: Autoconvert URL-like text to links"></MSwitch>
<MSwitch @bind-Value="typographer" HideDetails="true" Label="typographer: Enable some language-neutral replacement + quotes beautification"></MSwitch>

<MMarkdownIt Source="@source"
             Html="@html"
             Breaks="breaks"
             Linkify="linkify"
             Typographer="typographer"
             Class="mt-4 pa-1"
             Style="border: 1px lightgrey solid " />

@code {

    private string source = @"
- html: 
  <b>Bold</b>
- breaks:
  Convert '\n' in paragraphs into <br>
- linkify:
  https://blazor.masastack.com
- typographer:
  ""Smartypants, double quotes"" and 'single quotes'
";

    private bool html;
    private bool breaks;
    private bool linkify;
    private bool typographer;

}
